<!doctype html>
<html lang="en">
<head>
    <title>Code coverage report for src/components/changepsd/changepsd.vue</title>
    <meta charset="utf-8" />
    <link rel="stylesheet" href="..\..\..\prettify.css" />
    <link rel="stylesheet" href="..\..\..\base.css" />
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <style type='text/css'>
        .coverage-summary .sorter {
            background-image: url(..\..\..\sort-arrow-sprite.png);
        }
    </style>
</head>
<body>
<div class='wrapper'>
  <div class='pad1'>
    <h1>
      <a href="..\..\..\index.html">All files</a> / <a href="index.html">src/components/changepsd</a> changepsd.vue
    </h1>
    <div class='clearfix'>
      <div class='fl pad1y space-right2'>
        <span class="strong">0% </span>
        <span class="quiet">Statements</span>
        <span class='fraction'>0/57</span>
      </div>
      <div class='fl pad1y space-right2'>
        <span class="strong">0% </span>
        <span class="quiet">Branches</span>
        <span class='fraction'>0/22</span>
      </div>
      <div class='fl pad1y space-right2'>
        <span class="strong">0% </span>
        <span class="quiet">Functions</span>
        <span class='fraction'>0/15</span>
      </div>
      <div class='fl pad1y space-right2'>
        <span class="strong">0% </span>
        <span class="quiet">Lines</span>
        <span class='fraction'>0/57</span>
      </div>
    </div>
  </div>
  <div class='status-line low'></div>
<pre><table class="coverage">
<tr><td class="line-count quiet">1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251</td><td class="line-coverage quiet"><span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span></td><td class="text"><pre class="prettyprint lang-js">&lt;template&gt;
  &lt;div class="index"&gt;
    &lt;Header&gt;&lt;/Header&gt;
    &lt;div class="main"&gt;
      &lt;p class='current-nav'&gt;当前位置 : &lt;router-link to='index'&gt;首页&lt;/router-link&gt; &lt;i&gt; &gt; &lt;/i&gt;修改密码&lt;/p&gt;
      &lt;div class="infor personset"
           style="margin-bottom:0;"&gt;
        &lt;p class="title"&gt;修改密码&lt;/p&gt;
&nbsp;
        &lt;div class="form-container"&gt;
&nbsp;
          &lt;el-form :model="ruleForm"
                   :rules="rules"
                   ref="ruleForm"
                   label-width="184px"
                   class="demo-ruleForm"&gt;
            &lt;el-form-item label="账号 :"&gt;
              &lt;el-input v-model="ruleForm.userAccount"
                        disabled&gt;&lt;/el-input&gt;
            &lt;/el-form-item&gt;
            &lt;el-form-item label="手机号 :"
                          prop="mobileNo"&gt;
              &lt;el-input v-model="ruleForm.mobileNo"&gt;&lt;/el-input&gt;
            &lt;/el-form-item&gt;
            &lt;el-form-item label="手机验证码 :"
                          prop="smsCode"&gt;
              &lt;el-input v-model="ruleForm.smsCode"
                        style='width:238px;'&gt;&lt;/el-input&gt;
              &lt;el-button style='color:#9f90ef;'
                         @click="getCode"
                         v-show="codeFlag"&gt;点击获取&lt;/el-button&gt;
              &lt;el-button style='color:#666;background:#ccc;cursor:no-drop;'
                         id="smsCode"
                         v-show="!codeFlag"&gt;点击获取&lt;/el-button&gt;
            &lt;/el-form-item&gt;
            &lt;el-form-item label="旧密码 :"
                          prop="oldPasswd"&gt;
              &lt;el-input v-model="ruleForm.oldPasswd"
                        type='password'&gt;&lt;/el-input&gt;
            &lt;/el-form-item&gt;
            &lt;el-form-item label="新密码 :"
                          prop="newPasswd"&gt;
              &lt;el-input v-model="ruleForm.newPasswd"
                        type='password'&gt;&lt;/el-input&gt;
            &lt;/el-form-item&gt;
            &lt;el-form-item label="确认密码 :"
                          prop="newPasswd2"&gt;
              &lt;el-input v-model="ruleForm.newPasswd2"
                        type='password'&gt;&lt;/el-input&gt;
            &lt;/el-form-item&gt;
&nbsp;
          &lt;/el-form&gt;
          &lt;div class="bts"&gt;
            &lt;el-button type="primary"
                       @click="submitForm('ruleForm')"
                       class='sure'&gt;保存&lt;/el-button&gt;
            &lt;el-button @click="resetForm('ruleForm')"
                       class='cancel'&gt;取消&lt;/el-button&gt;
          &lt;/div&gt;
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;Footer /&gt;
  &lt;/div&gt;
&lt;/template&gt;
&nbsp;
&lt;script&gt;
<span class="cstat-no" title="statement not covered" >import Header from '../common/header'</span>
<span class="cstat-no" title="statement not covered" >import Footer from '../common/footer'</span>
<span class="cstat-no" title="statement not covered" >import config from "../../config.js"</span>
export default {
  components: {
    Header,
    Footer
  },
<span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >  data () {</span></span>
<span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >    var checkPhone = (rule, value, callback) =&gt; {</span></span>
<span class="cstat-no" title="statement not covered" >      if (!value) {</span>
<span class="cstat-no" title="statement not covered" >        return callback(new Error("手机号不能为空"));</span>
      } else {
<span class="cstat-no" title="statement not covered" >        const reg = /^1[3|4|5|7|8][0-9]\d{8}$/;</span>
<span class="cstat-no" title="statement not covered" >        console.log(reg.test(value));</span>
<span class="cstat-no" title="statement not covered" >        if (reg.test(value)) {</span>
<span class="cstat-no" title="statement not covered" >          callback();</span>
        } else {
<span class="cstat-no" title="statement not covered" >          return callback(new Error("请输入正确的手机号"));</span>
        }
      }
    }
<span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >    var checknewPasswd = (rule, val, callback) =&gt; {</span></span>
<span class="cstat-no" title="statement not covered" >      console.log(val)</span>
<span class="cstat-no" title="statement not covered" >      if (!val) {</span>
<span class="cstat-no" title="statement not covered" >        return callback(new Error('新密码不能为空'))</span>
<span class="cstat-no" title="statement not covered" >      } else if (!/^[0-9A-Za-z]{6,}$/.test(val)) {</span>
<span class="cstat-no" title="statement not covered" >        return callback(new Error('至少输入6个以上的数字或字母'))</span>
<span class="cstat-no" title="statement not covered" >      } else if (this.ruleForm.newPasswd == this.ruleForm.oldPasswd) {</span>
<span class="cstat-no" title="statement not covered" >        return callback(new Error('新密码不能和原密码相同'))</span>
      } else {
<span class="cstat-no" title="statement not covered" >        callback()</span>
      }
    }
<span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >    var checknewPasswd2 = (rule, val, callback) =&gt; {</span></span>
<span class="cstat-no" title="statement not covered" >      if (!val) {</span>
<span class="cstat-no" title="statement not covered" >        return callback(new Error('新密码不能为空'))</span>
      }
<span class="cstat-no" title="statement not covered" >      if (this.ruleForm.newPasswd != this.ruleForm.newPasswd2) {</span>
<span class="cstat-no" title="statement not covered" >        return callback(new Error('两次密码输入不一致'))</span>
      }
<span class="cstat-no" title="statement not covered" >      callback()</span>
    }
<span class="cstat-no" title="statement not covered" >    return {</span>
      uploadFlag: false,
      codeFlag: true,
      time: null,
      ruleForm: {
        userAccount: '',
        mobileNo: '',
        smsCode: '',
        oldPasswd: '',
        newPasswd: '',
        newPasswd2: ''
      },
      rules: {
        oldPasswd: [
          { required: true, message: "请输入原密码", trigger: "blur" }
        ],
        newPasswd: [
          { required: true, message: "请输入新密码", trigger: "blur" },
          {
            required: true,
            validator: checknewPasswd,
            trigger: "blur"
          }
        ],
        newPasswd2: [
          { required: true, message: "请再次输入新密码", trigger: "blur" },
          {
            required: true,
            validator: checknewPasswd2,
            trigger: "blur"
          }
        ],
        mobileNo: [
          { required: true, message: "请输入手机号", trigger: "blur" },
          {
            required: true,
            validator: checkPhone,
            trigger: "blur"
          }
        ],
        smsCode: [
          { required: true, message: "请输入手机验证码", trigger: "blur" }
        ]
      }
    }
&nbsp;
  },
<span class="fstat-no" title="function not covered" >  mounted () {</span>
<span class="cstat-no" title="statement not covered" >    this.ruleForm.userAccount = JSON.parse(localStorage.user).userAccount</span>
  },
<span class="fstat-no" title="function not covered" >  created () {</span>
&nbsp;
  },
  methods: {
<span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >    getCode () {</span></span>
<span class="cstat-no" title="statement not covered" >      var reg = /^1[3|4|5|7|8][0-9]\d{8}$/;</span>
<span class="cstat-no" title="statement not covered" >      if (reg.test(this.ruleForm.mobileNo)) {</span>
<span class="cstat-no" title="statement not covered" >        var t = 30;</span>
<span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >        this.time = setInterval(() =&gt; {</span></span>
<span class="cstat-no" title="statement not covered" >          this.codeFlag = false;</span>
<span class="cstat-no" title="statement not covered" >          t--;</span>
<span class="cstat-no" title="statement not covered" >          if (t != 0) {</span>
<span class="cstat-no" title="statement not covered" >            document.getElementById("smsCode").innerHTML = t + "s";</span>
          } else {
<span class="cstat-no" title="statement not covered" >            t = 0;</span>
<span class="cstat-no" title="statement not covered" >            clearInterval(this.time);</span>
<span class="cstat-no" title="statement not covered" >            this.codeFlag = true;</span>
          }
        }, 1000);
<span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >        this.$axios.post(config.baseUrl + "emergency/v1.0/sms/verifyCode", {</span></span>
          mobileNo: this.ruleForm.mobileNo
        })
          .then(res =&gt; {
<span class="cstat-no" title="statement not covered" >            if (res.data.meta.success) {</span>
<span class="cstat-no" title="statement not covered" >              this.$message.success(res.data.data.verifySuccess);</span>
            } else {
<span class="cstat-no" title="statement not covered" >              this.$message.warning(res.data.meta.message);</span>
            }
<span class="fstat-no" title="function not covered" >          })</span>
          .catch(response =&gt; {
<span class="cstat-no" title="statement not covered" >            console.log(response);</span>
          });
      } else {
<span class="cstat-no" title="statement not covered" >        this.$message.warning("请输入正确的手机号");</span>
      }
    },
<span class="fstat-no" title="function not covered" >    success (res) {//来自子组件 上传成功 关闭弹窗</span>
<span class="cstat-no" title="statement not covered" >      this.uploadFlag = false</span>
    },
<span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >    submitForm () {</span></span>
<span class="cstat-no" title="statement not covered" >      let params = {</span>
        mobileNo: this.ruleForm.mobileNo,
        newPasswd: this.$md5(this.ruleForm.newPasswd),
        oldPasswd: this.$md5(this.ruleForm.oldPasswd),
        smsCode: this.ruleForm.smsCode,
        userAccount: this.ruleForm.userAccount
      }
<span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >      this.$axios.post(config.baseUrl + 'emergency/v1.0/modify/password', params)</span></span>
        .then((res) =&gt; {
          // console.log(res)
<span class="cstat-no" title="statement not covered" >          if (res.data.meta.success) {</span>
<span class="cstat-no" title="statement not covered" >            this.$message.success(res.data.meta.message);</span>
<span class="cstat-no" title="statement not covered" >            this.$router.push('login')</span>
          } else {
<span class="cstat-no" title="statement not covered" >            this.$message.warning(res.data.meta.message)</span>
          }
&nbsp;
<span class="fstat-no" title="function not covered" >        }).catch((response) =&gt; {</span>
<span class="cstat-no" title="statement not covered" >          console.log(response);</span>
        })
    },
<span class="fstat-no" title="function not covered" >    resetForm (formName) {</span>
<span class="cstat-no" title="statement not covered" >      this.$refs[formName].resetFields();</span>
    }
  }
}
&lt;/script&gt;
&nbsp;
&lt;!-- Add "scoped" attribute to limit CSS to this component only --&gt;
&lt;style lang='less'&gt;
@import "../../../static/css/information.less";
.personset {
  .form-container {
    width: 766px;
    padding: 0 0 70px;
    margin: 0 auto;
    .el-form {
      margin-top: 34px;
    }
    .el-button {
      width: 118px;
      height: 42px;
      border-radius: 8px;
    }
    .el-input {
      width: 360px;
    }
  }
}
&lt;/style&gt;
&nbsp;</pre></td></tr>
</table></pre>
<div class='push'></div><!-- for sticky footer -->
</div><!-- /wrapper -->
<div class='footer quiet pad2 space-top1 center small'>
  Code coverage
  generated by <a href="https://istanbul.js.org/" target="_blank">istanbul</a> at Thu Jun 20 2019 14:29:28 GMT+0800 (GMT+08:00)
</div>
</div>
<script src="..\..\..\prettify.js"></script>
<script>
window.onload = function () {
        if (typeof prettyPrint === 'function') {
            prettyPrint();
        }
};
</script>
<script src="..\..\..\sorter.js"></script>
</body>
</html>
